package com.amado.course09String;

//java.lang.String
import java.lang.*;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Scanner;

public class StringHomeWork {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			System.out.println("1、管理员登陆 2、用户登陆");
			int menuSelect = scanner.nextInt();
			// 管理员登陆
			if (menuSelect == 1) {
				//用户登陆
				System.out.println("请输入用户名");
				String userName = scanner.next();
				System.out.println("请输入密码");
				String password = scanner.next();
				if("admin".equals(userName)&& "admin".equals(password)) {
					System.out.println("1、办卡 2、查看用户所有信息");
				}else {
					System.out.println("用户名密码错误");
				}
				//用户登陆
			} else if (menuSelect == 2) {
				System.out.println("请输入用户名");
				String userName = scanner.next();
				System.out.println("请输入密码");
				String password = scanner.next();
				//判断用户名密码,从用户数组当中判断
				int userIndex=-1;
				for(int i=0;i<11;i++) {
					userIndex  =1;
				}
				//登陆成功
				if(userIndex!=-1) {
					System.out.println("1、存款 2、取款 3、修改密码 4、查询余额 5、转账  6、查询交易记录");
					menuSelect = scanner.nextInt();
				}else {
					
				}
			} else {
				System.out.println("菜单选择错误");
			}

		}
	}
}
